﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage/Adminitrator.master"
    AutoEventWireup="true" CodeFile="Details.aspx.cs" Inherits="admin_Products_Details"
    ValidateRequest="false" %>

<%@ Register Assembly="AjaxControlToolkit" Namespace="AjaxControlToolkit" TagPrefix="asp" %>
<%@ Register Assembly="FredCK.FCKeditorV2" Namespace="FredCK.FCKeditorV2" TagPrefix="FCKeditorV2" %>
<asp:Content ID="Content1" ContentPlaceHolderID="Content" runat="Server">
    <asp:ToolkitScriptManager ID="ToolkitScriptManager1" runat="server">
    </asp:ToolkitScriptManager>
    <h1 id="h3Title" class="title" runat="server">
        Thêm mới sản phẩm</h1>
    <div class="detail ">
        <fieldset class="fieldset">
            <legend>Thông tin sản phẩm</legend>
            <table style="width: 100%">
                <tr>
                    <td style="width: 120px">
                        Danh mục&nbsp;
                    </td>
                    <td style="padding-left: 30px">
                        <asp:DropDownList Width="300px" ID="dropParent" runat="server" CssClass="dropdown"
                            AutoPostBack="true" OnSelectedIndexChanged="dropParent_SelectedIndexChanged" />
                        (Chọn danh mục sản phẩm là con của các danh mục cha)
                    </td>
                </tr>
            </table>
            <%--<tr>
          <td>
            Ảnh thumbnails
          </td>
          <td style="padding-left: 30px">
            <asp:FileUpload ID="fileUpload_thumb" runat="server" /> &nbsp; &nbsp; Kích thước 150 x 135 (px)
          </td>
        </tr>--%>
            <asp:TabContainer ID="TabContainer1" runat="server">
                <asp:TabPanel ID="tbMota" HeaderText="Thông tin" runat="server">
                    <ContentTemplate>
                        <table>
                            <tr>
                                <td>
                                    Mã sản phẩm
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtMaSP" runat="server" CssClass="textBox" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td valign="top" style="padding-top: 8px">
                                    Tên sản phẩm
                                </td>
                                <td style="padding-left: 27px;">
                                    <table>
                                        <tr>
                                            <td>
                                                <asp:TextBox ID="txtName" runat="server" CssClass="textBox" Width="580px" />
                                            </td>
                                        </tr>
                                        <tr style="display: none;">
                                            <td align="right">
                                                <span class="lang">En</span>
                                            </td>
                                            <td>
                                                <asp:TextBox ID="txtName_En" runat="server" CssClass="textBox" Width="580px" />
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Giá
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtCost" runat="server" CssClass="textBox" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Giá Sales
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtCost_Sale" runat="server" CssClass="textBox" Width="300px" />&nbsp;
                                    <asp:CheckBox ID="checkNoneSale" runat="server" Text="Bỏ giá Sales" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Số lượng
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtQuantity" runat="server" Width="300px" CssClass="textBox" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Link gốc
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtOrigin" runat="server" CssClass="textBox" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Tình trạng
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:DropDownList ID="dropStatus" CssClass="dropdown" runat="server" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Label
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:DropDownList ID="dropLabel" CssClass="dropdown" runat="server" Width="300px">
                                        <asp:ListItem Text="Không chọn" Value="0" />
                                    </asp:DropDownList>
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Thương hiệu
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:DropDownList ID="dropBrand" CssClass="dropdown" runat="server" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Kích thước
                                </td>
                                <td style="padding-left: 30px;">
                                    <asp:CheckBoxList ID="checkSize" runat="server" CssClass="check-colour" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Màu sắc
                                </td>
                                <td style="padding-left: 30px;">
                                    <ul style="border: 1px solid #cccccc; padding: 10px;">
                                        <asp:Repeater ID="rptColor" runat="server" OnItemDataBound="rptColor_ItemDataBound">
                                            <ItemTemplate>
                                                <li style="float: left; width: 180px; height: 50px;">
                                                    <img src='/Images/Colour/<%#Eval("Image") %>' alt='<%#Eval("Name") %>' style='height: 30px;
                                                        width: 30px;' />
                                                    <asp:CheckBox CssClass="abc" ID="CheckBoxList1" runat="server" Text='<%#Eval("Name") %>' />
                                                    <asp:Label ID="idColors" Text='<%#Eval("Id") %>' Visible="false" runat="server" />
                                                </li>
                                            </ItemTemplate>
                                        </asp:Repeater>
                                        <div style="clear: both;">
                                        </div>
                                    </ul>
                                </td>
                            </tr>
                        </table>
                    </ContentTemplate>
                </asp:TabPanel>
                <asp:TabPanel ID="TabPanel1" HeaderText="Ưu đãi & Mô tả sản phẩm" runat="server">
                    <ContentTemplate>
                        <table>
                            <tr>
                                <td valign="top" style="padding-top: 20px">
                                    Ưu đãi
                                </td>
                                <td style="padding-top: 20px; padding-left: 30px;">
                                    <asp:TextBox ID="txtDescription" runat="server" Width="810px" TextMode="MultiLine"
                                        Rows="10" />
                                </td>
                            </tr>
                            <tr>
                                <td valign="top" style="padding-top: 20px">
                                    Mô tả
                                </td>
                                <td style="padding-top: 20px; padding-left: 30px;">
                                    <table>
                                        <tr>
                                            <td style="padding-bottom: 10px">
                                                <FCKeditorV2:FCKeditor ID="fckEditor" runat="server" Width="810px" Height="380px"
                                                    BasePath="~/fckeditor/">
                                                </FCKeditorV2:FCKeditor>
                                            </td>
                                        </tr>
                                        <tr style="display: none;">
                                            <td align="right" valign="top">
                                                <span class="lang">En</span>
                                            </td>
                                            <td style="padding-bottom: 10px">
                                                <FCKeditorV2:FCKeditor ID="fckEditor_En" runat="server" Width="810px" Height="380px"
                                                    BasePath="~/fckeditor/">
                                                </FCKeditorV2:FCKeditor>
                                            </td>
                                        </tr>
                                    </table>
                                </td>
                            </tr>
                        </table>
                    </ContentTemplate>
                </asp:TabPanel>
                <asp:TabPanel ID="TabPanel2" HeaderText="Ảnh sản phẩm & Cài đặt" runat="server">
                    <ContentTemplate>
                        <table>
                            <tr>
                                <td colspan="2">
                                    <p>
                                        <font style="color: Red"><b>Lưu ý : Nhập ảnh đúng kích thước để hiện thị được đẹp nhất
                                            (Kích thước 1000px X 693px)</b></font></p>
                                </td>
                            </tr>
                            <tr>
                                <td style="width: 120px">
                                    Hình đại diện
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_01" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_01" runat="server" Visible="false" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Ảnh liên quan 1
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_02" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_02" runat="server" Visible="false" />&nbsp; &nbsp; &nbsp;<asp:CheckBox
                                            Visible="false" ID="check_DelImage_02" runat="server" Text="Bỏ ảnh này" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Ảnh liên quan 2
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_03" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_03" runat="server" Visible="false" />&nbsp; &nbsp; &nbsp;<asp:CheckBox
                                            Visible="false" ID="check_DelImage_03" runat="server" Text="Bỏ ảnh này" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Ảnh liên quan 3
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_04" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_04" runat="server" Visible="false" />&nbsp; &nbsp; &nbsp;<asp:CheckBox
                                            Visible="false" ID="check_DelImage_04" runat="server" Text="Bỏ ảnh này" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Ảnh liên quan 4
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_05" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_05" runat="server" Visible="false" />&nbsp; &nbsp; &nbsp;<asp:CheckBox
                                            Visible="false" ID="check_DelImage_05" runat="server" Text="Bỏ ảnh này" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Ảnh liên quan 5
                                </td>
                                <td valign="middle" style="padding-left: 30px;">
                                    <asp:FileUpload ID="file_Image_06" runat="server" />&nbsp;<asp:Image Height="30px"
                                        ID="image_06" runat="server" Visible="false" />&nbsp; &nbsp; &nbsp;<asp:CheckBox
                                            Visible="false" ID="check_DelImage_06" runat="server" Text="Bỏ ảnh này" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Từ khóa
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtTag" runat="server" CssClass="textBox" Width="600px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Tình trạng
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:RadioButton ID="radioEnable" GroupName="radioStatus" runat="server" Checked="true" />Bật
                                    <asp:RadioButton ID="radioVisible" GroupName="radioStatus" runat="server" />Tắt
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    Lượt xem
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtView" runat="server" CssClass="textBox" Width="300px" />
                                </td>
                            </tr>
                            <tr id="trCreatedDate" runat="server">
                                <td>
                                    Ngày tạo
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:TextBox ID="txtCreatedDate" runat="server" CssClass="textBox" Width="300px" />
                                </td>
                            </tr>
                            <tr>
                                <td>
                                    &nbsp;
                                </td>
                                <td style="padding-left: 30px">
                                    <asp:CheckBox ID="checkKM" runat="server" />
                                    Sản phẩm mới &nbsp;|&nbsp;
                                    <asp:CheckBox ID="checkHot" runat="server" />
                                    Sản phẩm bán chạy
                                </td>
                            </tr>
                        </table>
                    </ContentTemplate>
                </asp:TabPanel>
            </asp:TabContainer>
            <%-- <tr>
          <td>
            Màu sắc
          </td>
          <td style="padding-left: 30px;">
            <asp:CheckBoxList ID="checkColour" runat="server" RepeatLayout="Table" CssClass="check-colour" /><asp:Image Height="30px" ID="imageColor" runat="server"/>
          </td>
        </tr>--%>
            <table id="infoOk" runat="server">
                <tr>
                    <td>
                        &nbsp;
                    </td>
                    <td style="padding-top: 10px; padding-left: 30px">
                        <asp:Button ID="btnOk" runat="server" Text="" CssClass="button btn-save" OnClick="btnOk_Click" />
                        <input type="reset" value="" class="button btn-reset" />
                        <asp:HyperLink ID="btnBack" runat="server" Text="Danh sách" CssClass="button btn-back"
                            NavigateUrl="~/admin/Products/List.aspx" />
                    </td>
                </tr>
            </table>
        </fieldset>
    </div>
    <p style="padding-left: 10px">
        <asp:Literal ID="lbThongBao" runat="server" />
    </p>
    </table>
</asp:Content>
